import java.util.Scanner;

/**
 * @author gao
 * @date 2025/9/24 22:02
 */

public class Solution {
    public String addBinary(String a, String b) {
        StringBuilder ret = new StringBuilder();
        int i = a.length() - 1, j = b.length() - 1, carry = 0;

        // 当至少还有一个字符串未遍历完时，继续循环
        while (i >= 0 || j >= 0) {
            int aBit = (i >= 0) ? a.charAt(i--) - '0' : 0;
            int bBit = (j >= 0) ? b.charAt(j--) - '0' : 0;

            // 计算当前位的和
            int sum = aBit + bBit + carry;

            // 将当前位的结果添加到结果中
            ret.append(sum % 2);

            // 更新进位
            carry = sum / 2;
        }

        // 处理最后的进位
        if (carry > 0) {
            ret.append(carry);
        }

        return ret.reverse().toString();
    }

    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        while (in.hasNext()) {
            String a = in.nextLine();
            String b = in.nextLine();
            Solution solution = new Solution();
            System.out.println(solution.addBinary(a, b));
        }
    }
}